<!DOCTYPE html>
<html>

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
    <meta http-equiv="Pragma" content="no-cache">
    <meta http-equiv="Cache-Control" content="no-cache">
    <meta http-equiv="Expires" content="0">
    <meta name="format-detection" content="telephone=no" />
    <meta name="format-detection" content="telephone=no" />
    <meta name="format-detection" content="email=no" />
    <meta name="format-detection" content="address=no" />
    <meta name="format-detection" content="date=no" />
    <title>新人礼领奖平台</title>
    <script type="text/javascript">
        !function (N, M) { function L() { var a = I.getBoundingClientRect().width; a / F > 540 && (a = 540 * F); var d = a / 10; I.style.fontSize = d + "px", D.rem = N.rem = d } var K, J = N.document, I = J.documentElement, H = J.querySelector('meta[name="viewport"]'), G = J.querySelector('meta[name="flexible"]'), F = 0, E = 0, D = M.flexible || (M.flexible = {}); if (H) { console.warn("将根据已有的meta标签来设置缩放比例"); var C = H.getAttribute("content").match(/initial\-scale=([\d\.]+)/); C && (E = parseFloat(C[1]), F = parseInt(1 / E)) } else { if (G) { var B = G.getAttribute("content"); if (B) { var A = B.match(/initial\-dpr=([\d\.]+)/), z = B.match(/maximum\-dpr=([\d\.]+)/); A && (F = parseFloat(A[1]), E = parseFloat((1 / F).toFixed(2))), z && (F = parseFloat(z[1]), E = parseFloat((1 / F).toFixed(2))) } } } if (!F && !E) { var y = N.navigator.userAgent, x = (!!y.match(/android/gi), !!y.match(/iphone/gi)), w = x && !!y.match(/OS 9_3/), v = N.devicePixelRatio; F = x && !w ? v >= 3 && (!F || F >= 3) ? 3 : v >= 2 && (!F || F >= 2) ? 2 : 1 : 1, E = 1 / F } if (I.setAttribute("data-dpr", F), !H) { if (H = J.createElement("meta"), H.setAttribute("name", "viewport"), H.setAttribute("content", "initial-scale=" + E + ", maximum-scale=" + E + ", minimum-scale=" + E + ", user-scalable=no"), I.firstElementChild) { I.firstElementChild.appendChild(H) } else { var u = J.createElement("div"); u.appendChild(H), J.write(u.innerHTML) } } N.addEventListener("resize", function () { clearTimeout(K), K = setTimeout(L, 300) }, !1), N.addEventListener("pageshow", function (b) { b.persisted && (clearTimeout(K), K = setTimeout(L, 300)) }, !1), "complete" === J.readyState ? J.body.style.fontSize = 12 * F + "px" : J.addEventListener("DOMContentLoaded", function () { J.body.style.fontSize = 12 * F + "px" }, !1), L(), D.dpr = N.dpr = F, D.refreshRem = L, D.rem2px = function (d) { var c = parseFloat(d) * this.rem; return "string" == typeof d && d.match(/rem$/) && (c += "px"), c }, D.px2rem = function (d) { var c = parseFloat(d) / this.rem; return "string" == typeof d && d.match(/px$/) && (c += "rem"), c } }(window, window.lib || (window.lib = {}));
    </script>
    <link rel="stylesheet" type="text/css" href="./js/swiper-3.3.1.min.css" />
    <style>
        * {
            padding: 0;
            margin: 0;
        }

        li {
            list-style: none;
        }

        body,
        html {
            width: 100%;
            height: 100%;
        }

        .mopup {
            position: absolute;
            overflow: hidden;
            display: none;
            top: 0;
            z-index: 999;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, .72);
            color: #7f4a0b;
        }


        .bg {
            width: 100%;
            min-height: 100%;
            background: url('./img/bg1.png?v=1');
            background-size: 100% 100%;
            overflow: hidden;
            position: relative;
        }

        input {
            border: 0;
            width: 3.45rem;
            height: 0.91rem;
            background: rgba(255, 255, 255, 1);
            border-radius: 0.13rem;
            display: block;
            margin-left: 2.2rem;
            padding: 0 0.2rem;
            font-size: 0.29rem;
            -moz-box-shadow: 0px 0px 0.15rem #DF3133 inset;
            /* For Firefox3.6+ */
            -webkit-box-shadow: 0px 0px 0.15rem #DF3133 inset;
            /* For Chrome5+, Safari5+ */
            box-shadow: 0px 0px 0.15rem #DF3133 inset;
            /* For Latest Opera */
        }

        ::-webkit-input-placeholder {
            color: #F0BE80;
        }

        ::-moz-placeholder {
            color: #F0BE80;
        }

        /* firefox 19+ */

        :-ms-input-placeholder {
            color: #F0BE80;
        }

        /* ie */

        input:-moz-placeholder {
            color: #F0BE80;
        }

        #code {
            position: absolute;
            top: 71.5%;

        }

        #yz {
            position: absolute;
            top: 79.5%;
            width: 2.7rem;
        }

        #qrcode {
            width: 2.19rem;
            height: 0.85rem;
            display: inline-block;
            position: absolute;
            top: 79.6%;
            left: 5.5rem;
        }

        #qrcode img {
            width: 100%;
            height: 100%;
        }

        #send {
            width: 5.53rem;
            height: 0.92rem;
            position: absolute;
            top: 88%;
            left: 2.3rem;
        }

        .uncode {
            display: block;
            width: 1.65rem;
            height: 0.92rem;
            background: url('./img/uncode.png?v=1');
            background-size: 100% 100%;
            position: absolute;
            top: 71.5%;
            left: 6.12rem;
        }

        .rule {
            position: absolute;
            width: .83rem;
            height: 1.64rem;
            right: 0;
            top: 87.5%;

        }

        .frame1,
        .frame0 {
            width: 7.65rem;
            height: 4.2rem;
            background: url('./img/frame1.png?v=2');
            background-size: 100% 100%;
            position: absolute;
            top: 7rem;
            left: 1.2rem;

        }

        .frame0 {
            background: url('./img/frame2.png?v=2');
            background-size: 100% 100%;
        }

        .frame0 p,
        .frame1 p {
            font-size: 0.32rem;
            font-family: HYQiHei-FZS;
            color: rgba(49, 49, 49, 1);
            padding: 0 0.3rem;
            text-align: center;
            margin-top: 1.1rem;

        }

        .frame0 p {
            margin-top: 1.4rem;
        }

        .yihou,
        .goCoupon,
        .cancel {
            width: 2.81rem;
            height: 0.75rem;
            display: inline-block;
            position: absolute;
            top: 2.7rem;
        }

        .yihou,
        .cancel {
            left: 0.75rem;
        }

        .goCoupon {
            right: 0.75rem;
        }

        .again {
            width: 3.8rem;
            height: 0.75rem;
            display: inline-block;
            position: absolute;
            top: 2.6rem;
            left: 2rem;
        }

        .framerule {
            width: 8.2rem;
            height: 11.8rem;
            background: url('./img/framerule.png?v=1');
            background-size: 100% 100%;
            position: absolute;
            top: 1.97rem;
            left: 1rem;
        }

        .ruleClose {
            width: 1rem;
            height: 1rem;
            position: absolute;
            top: 0.13rem;
            right: 0.3rem;
        }

        /* .framerule ol {
            width: 8.2rem;
            height: 9rem;
            box-sizing: border-box;
            padding: 0 0.5rem;
            margin-top: 1.5rem;
            color: #313131;
            overflow: scroll;
        } */

        #ruleUrl{
            width: 8.2rem;
            height: 9rem;
            margin-top: 1.5rem;
        }

        .xyj {
            background: url('./img/xyj.jpg?v=1');
            background-size: 100% 100%;
        }

        .zhongshu {
            background: url('./img/zhongshu.jpg?v=1');
            background-size: 100% 100%;
        }

        .bao51 {
            background: url('./img/bao51.jpg?v=1');
            background-size: 100% 100%;
        }

        .baotq {
            background: url('./img/baotq.jpg?v=1');
            background-size: 100% 100%;
        }

        .erweimaCon {
            margin: 30% auto 0;
            width: 8.387rem;
            height: 57.801%;
            /*48.801%*/
            background: url("./img/letter.png?v=1") no-repeat;
            background-size: 100% 100%;
            overflow: hidden;
        }

        .erweimaCon p {
            padding: 2.367rem 1.333rem .267rem;
        }

        .erweimaCon .close {
            float: right;
            margin-top: 12.377%;
            width: 1.147rem;
            height: 1.147rem;
        }

        .erweima {
            transform: translateX(56%);
            width: 4.0rem;
            height: 4.0rem;
            background: url("./img/erweima?v=1.jpg");
            background-size: 100% 100%;
        }

        .failClose {
            width: .5rem;
            height: .5rem;
            position: absolute;
            right: .15rem;
            top: .15rem;
        }
    </style>
</head>

<body>
    <div class="bg">
        <input type="text" id="code" placeholder="请输入领取码">
        <input type="text" id="yz" placeholder="请输入验证码">
        <div id="qrcode">
            <img onclick="imgchange(this)">
        </div>
        <div id="send"></div>
        <a class="uncode" href="./answer.html"></a>
        <div class="rule"></div>
    </div>
    <!-- 输入正确 -->
    <div class="mopup suc">
        <div class="frame1">
            <div class="failClose"></div>
            <p>恭喜您获得300MB流量兑换券，进入卡券中心可兑换流量，点击【前去签到领话费】每月话费领不停！</p>
            <div class="yihou"></div>
            <div class="goCoupon"></div>
        </div>
    </div>
    <!-- 输入错误 -->
    <div class="mopup fai">
        <div class="frame0">
            <div class="failClose"></div>
            <p></p>
            <div class="again"></div>
        </div>
    </div>
    <!-- 活动规则 -->
    <div class="mopup rulemopup">
        <div class="framerule">
            <div class="ruleClose"></div>
            <!-- <ol>
                <li>1.即日起—2019年1月31日24:00山东移动客户首次绑定“中国移动10086”公众号并在公众号输入框中发送“新人礼”根据回复语提示进行操作，符合首绑绑定规则的客户可免费领取300MB流量兑换券。</li>
                <li>2.活动期间客户不可解除绑定，否则活动数据清零，无法赠送流量；活动期间如果微信号与手机号码绑定关系发生变更，仅充值当前绑定微信号的流量奖励；</li>
                <li>3.客户获奖后系统会自动将奖品兑换券赠送至“中国移动10086”微信公众号“卡券中心”账户内。卡券中心流量券需要兑换及使用后才能自动充值到手机账户内，流量券有兑换使用时限，具体兑换流程及时限详见卡券中心说明。</li>
                <li>4.客户获得流量的使用规则详见卡券中心商品说明。客户每自然月获赠流量2GB封顶，超出部分将无法到账。2GB流量含在“中国移动10086”微信公众号、“山东移动”掌厅APP及其他移动微信公众号渠道获得的，且需要在“山东移动APP”卡券中心兑换使用的流量奖励。请客户注意合理选择商品兑换！</li>
                <li>5.手机号码必须真实有效且状态正常，如因客户提供信息原因或手机状态原因导致流量无法赠送，我公司不进行补送；</li>
                <li>6.欠费、停机、未进行实名认证客户，将影响流量的赠送；副卡、MO套餐、无极变速套餐、数据卡、随心卡、行业应用卡、信息机用户无法享受流量赠送；</li>
                <li>7.活动期间若出现非正常参与活动行为，经核实后一律取消获奖资格。</li>
            </ol> -->
            <div id="ruleUrl"></div>    
        </div>
    </div>
    <!-- 没绑定公众号 -->
    <div class="mopup erweima_mop">
        <div class="erweimaCon">
            <div class="close"></div>
            <p>啊哦，还没绑定哦~长按二维码绑定“中国移动10086”微信公众号哦~</p>
            <img src="img/erweima.jpg" alt="" class="erweima" />
        </div>
    </div>
</body>
<script type="text/javascript" src="js/jquery-2.1.1.min.js"></script>
<script src="https://wx.online-cmcc.cn/shandong/wx/otherSamllProject/commJs/iframe.js"></script>
<script src="js/swiper-3.3.1.jquery.min.js"></script>
<script> 
    var Url = 'https://www.shandong10086.com/pull-user/'

    $('body').css({ 'height': $(window).height() })
    //活动规则
    $('.rule').on('click', function () {
        $('.rulemopup').show()
        //61 双
        var url = rule('https://www.shandong10086.com/sdCmosService/activitySupport/preview.do?id=63','https://www.shandong10086.com/sdCmosService/activitySupport/preview.do?id=61','pullNew',0)
        $('#ruleUrl').load(url)
    })
    //活动规则关闭
    $('.ruleClose').on('click', function () {
        $('.rulemopup').hide()
    })
    //getUserinfo
    var mobile;
    var giftCode = GetQueryString("giftCode");
    if (giftCode) {
        $('#code').val(giftCode)
    }
    var nickName
    var isCode = localStorage.getItem('pullNewCode10086')
    var code = GetQueryString("code");
    var openId
    localStorage.setItem('pullNewCode10086', code)
    if (code && isCode != code) {
        $.ajax({
            type: "get",
            url: Url + "/userInfoCtl/getuserinfo",
            data: {
                "code": code
            },
            success: function (data) {
                mobile = data.data.mobile;
                if (mobile) {
                    nickName = data.data.nickName;
                    openId = data.data.openid
                    var provinceCode = data.data.provinceCode
                    if (provinceCode != 531) {//是否是山东省
                        $('.erweima_mop').show()
                        $('.erweima_mop p').text('非山东用户不可参加')
                    } else {
                        localStorage.setItem('pullNewMobile10086', mobile)
                        localStorage.setItem('pullNewnickName10086', nickName)
                        localStorage.setItem('pullNewopenId10086', openId)
                        $('#qrcode img').prop('src', Url + '/captcha?phone=' + encodeURIComponent(mobile))
                    }
                }else{
                    $('.erweima_mop').show()
                }
            }
        })
    }else {
        mobile = localStorage.getItem('pullNewMobile10086')
        nickName = localStorage.getItem('pullNewnickName10086')
        openId = localStorage.getItem('pullNewopenId10086')
         //mobile = '4+jIg/WkCoQg8u2C/Y436A=='
        //nickName = '透nm'
        $('#qrcode img').prop('src', Url + '/captcha?phone=' + encodeURIComponent(mobile))
    } 


    function imgchange(_this) {
        var d = new Date();
        _this.src = Url + '/captcha?phone=' + encodeURIComponent(mobile) + '&t=' + d.getTime();
    }
    $('#send').off('click').on('click', function () {
        if ($('#code').val() && $('#yz').val()) {
            giftCode = $('#code').val()
            $.ajax({
                type: "post",
                url: Url + '/newGift',
                data: {
                    phone: mobile, giftCode: giftCode, nickName: nickName, verifyCode: $('#yz').val(), openid: openId
                },
                success: function (res) {
                    if (res.code == 0000) {
                        $.post('https://www.shandong10086.com/rotor/initCtl/insertBWR', { playerPhone: mobile, listType: 1, gameId: 7, flag: 'laxin' })
                        $('.suc').show()
                    } else {
                        $('.fai').show()
                        $('.fai p').text(res.msg)
                        if (res.code == 2003) {
                            $('.fai p').text('对不起，您不符合新人礼领取规则。')
                        }
                    }
                }
            })

        } else {
            alert('请填写完整再进行提交')
        }

    })
    //错误
    $('.again').on('click', function () {
        window.location.href = 'https://www.shandong10086.com/sdCmosService/signnew/index.do'
    })
    $('.failClose').on('click', function () {
        $('.fai').hide()
        $('.suc').hide()
    })
    //去卡券中心
    $('.goCoupon').on('click', function () {
        window.location.href = 'https://www.shandong10086.com/sdCouponService/exchangeCenter/exchangeInit.do'
    })
    //以后
    $('.yihou').on('click', function () {
        window.location.href = 'https://www.shandong10086.com/sdCmosService/signnew/index.do'
    })

    function GetQueryString(name) {
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
        var r = window.location.search.substr(1).match(reg);
        if (r != null) return unescape(r[2]);
        return null;
    }  
</script>

</html>